<!DOCTYPE HTML>
<html>
<head>
	<link rel="stylesheet" href="<?php echo $this->baseUrl("admin/css/main.css")?>"></link>
	<?php echo $this->headLink();?>
</head>
<body>
<section class="main">
	<aside class="sidebar">
		<ul id="menu">
		<?php 
			$curr_controller = Zend_Controller_Front::getInstance()->getRequest()->getControllerName();
			$curr_action = Zend_Controller_Front::getInstance()->getRequest()->getActionName();
			$menus = array(
					'Question' => array(array('c' => 'question', 'a' => 'add', 'text' => 'Add/edit question'))
					);
			foreach ($menus as $name => $menu) {
				echo '<li>';
				echo "<a>{$name}</a>";
				echo '<ul>';
				foreach ($menu as $item) {
					$class = '';
					if (($item['c'] == $curr_controller) && ($item['a'] == $curr_action)) {
						$class = 'active';
					}
					echo '<li class="' . $class . '"><a href="' . $this->url(array('action' => $item['a'], 'controller' => $item['c'])) . '">' . $item['text'] . '</a></li>';
				}
				echo '</ul></li>';
			}
		?>
		</ul>
	</aside>
	<section class="content">
		<?php echo $this->layout()->content; ?>
	</section>
</section>	
	<?php echo $this->headScript();?>
</body>
</html>